<template>
	<view>
		<view class="setline"></view>
		<view class="set flex_between" @click="$fun.jump(`./personal`)">
			<view class="">个人信息</view>
			<image src="../../static/goin.png" mode=""></image>
		</view>
		<view class="set flex_between">
			<view class="">手机号</view>
			<view class="flex">
				{{phone}}
				<!-- <image src="../../static/goin.png" mode=""></image> -->
			</view>
		</view>
		<view class="set flex_between" @click="$fun.jump(`/pageB/makemode/makemode`)">
			<view class="">收款方式</view>
			<image src="../../static/goin.png" mode=""></image>
		</view>
		<view class="set flex_between" @click="$fun.jump(`/pageA/public/editPwd?type=0&title=&phone=${phone}`)">
			<view class="">密码修改</view>
			<image src="../../static/goin.png" mode=""></image>
		</view>
		<view class="set flex_between" @click="$fun.jump(`/pageA/public/editPwd?type=1&title=支付&phone=${phone}`)">
			<view class="">支付密码修改</view>
			<image src="../../static/goin.png" mode=""></image>
		</view>
		<view class="set flex_between" @click="$fun.jump(`/pageA/changeUser`)">
			<view class="">切换账号</view>
			<image src="../../static/goin.png" mode=""></image>
		</view>
		<!-- #ifdef APP-PLUS -->
		<view class="set flex_between">
			<view class="">万寿园</view>
			<text class="cell-tip" style="color: #FF5534;">{{version}}</text>
		</view>
		<!-- #endif -->
		<view class="setline"></view>
		<view class="set flex_between" @click="toLogout">
			<view class="" style="color: #FF3333;">退出登录</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				phone: '',
				version: ''
			}
		},
		onShow() {
			// #ifdef APP-PLUS
			plus.runtime.getProperty(plus.runtime.appid, async (inf) => {
				this.version = 'V' + inf.version
				console.log('当前版本', inf.version);
			})
			// #endif
		},
		onLoad(option) {
			this.phone = option.mobile
		},
		methods: {
			//退出登录
			toLogout() {
				uni.showModal({
					content: '确定要退出登录么',
					success: (e) => {
						if (e.confirm) {
							this.$fun.msg('退出成功')
							uni.clearStorage()
							setTimeout(() => {
								uni.reLaunch({
									url: '/pageA/public/login'
								})
							}, 200)
						}
					}
				});
			},
		}
	}
</script>

<style lang="scss">
	page {
		background: #F2EDED;
	}

	.setline {
		width: 750rpx;
		height: 16rpx;
		background: #F2F2F2;
	}

	.set {
		width: 750rpx;
		height: 100rpx;
		line-height: 100rpx;
		background: #FFFFFF;
		padding: 0 30rpx;
		font-weight: 500;
		font-size: 28rpx;
		color: #19181A;
		border-bottom: 1rpx solid #F2F2F2;

		image {
			width: 48rpx;
			height: 48rpx;
		}
	}
</style>